<?php
error_reporting(0);
set_error_handler(function ($type,$message,$file,$line){
    print_r('<b>set_error_handler: ' . $type . ':' . $message . ' in ' . $file . ' on ' . $line . ' line .</b><br />');
});
register_shutdown_function(function (){
    if ($error = error_get_last()) {
    var_dump('<b>register_shutdown_function: Type:' . $error['type'] . ' Msg: ' . $error['message'] . ' in ' . $error['file'] . ' on line ' . $error['line'] . '</b>');
    }
});